<template>
  <div class="box">
    <div class="list" @click="fn">
      <div class="left">
        <p>{{ title }}</p>
      </div>
      <div class="right">
        <slot name="default"></slot>
        <span >{{val}}</span>
        <span class="span"><van-icon name="arrow" /></span>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  props: ["title", "val"],
  data() {
    return {
      isLink: {
        type: Boolean,
        default: false,
      },
    };
  },
  methods: {
      fn(){
          this.$emit('onList')
      }
  },
};
</script>
<style lang="scss" scoped>
.box {
  padding: 0 20px;
  box-sizing: border-box;
  .list {
    display: flex;
    justify-content: space-between;
    width: 100%;
    height: 80px;
    line-height: 80px;
    font-size: 25px;
    color: grey;
    border-bottom: 1px solid gainsboro;
    .right {
      .span{
        color: gainsboro;
        margin-left: 10px;
      }
    }
  }
}
img{
    width: 70px;
    height: 70px;
    border-radius: 50%;
    vertical-align: middle;

}
</style>